package com.handpay.zztong.hp.notification.bean;

import android.os.Parcel;
import android.os.Parcelable;

import com.j256.ormlite.field.DatabaseField;
import com.j256.ormlite.table.DatabaseTable;

/**
 * Created by fplei on 2017/5/17.
 */
@DatabaseTable(tableName = "t_push")
public class PushMessgaeBody implements Parcelable {
    @DatabaseField(generatedId = true)
    private int id;
    @DatabaseField
    private String userId;
    @DatabaseField
    private String content;
    @DatabaseField
    private String title;
    @DatabaseField
    private String time;

    public int getId() {
        return id;
    }

    public String getUserId() {
        return userId;
    }

    public String getContent() {
        return content;
    }

    public String getTitle() {
        return title;
    }

    public String getTime() {
        return time;
    }

    public void setId(int id) {
        this.id = id;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public void setTime(String time) {
        this.time = time;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeInt(this.id);
        dest.writeString(this.userId);
        dest.writeString(this.content);
        dest.writeString(this.title);
        dest.writeString(this.time);
    }

    public PushMessgaeBody() {
    }

    protected PushMessgaeBody(Parcel in) {
        this.id = in.readInt();
        this.userId = in.readString();
        this.content = in.readString();
        this.title = in.readString();
        this.time = in.readString();
    }

    public static final Creator<PushMessgaeBody> CREATOR = new Creator<PushMessgaeBody>() {
        @Override
        public PushMessgaeBody createFromParcel(Parcel source) {
            return new PushMessgaeBody(source);
        }

        @Override
        public PushMessgaeBody[] newArray(int size) {
            return new PushMessgaeBody[size];
        }
    };
}
